package reader;

import domain.Card;
import javafx.fxml.FXML;
import javafx.scene.control.TextField;

public class CardReader extends TextField {

	private Card card;

	public Card readCard(String cardNo) {
		card = new Card(cardNo); //创建card实例
		this.setText(cardNo);
		this.setEditable(false);
		return card;
	}

	public void exitCard() {
		this.setText("");
		this.setEditable(true);//模拟退卡
		card = null;
	}
	
	
}
